<template>
  <div class="HomeStyleBox">
      列表
      <router-view></router-view>
      <button>{{$t("header.login")}}</button>
      <button @click="changeS('zh')">中文</button>
      <button @click="changeS('en')">英文</button>
      <button @click="jump('')">发布</button>
      <button @click="jump('1')">编辑</button>
  </div>
</template>

<script>
export default {
     created() {
       console.log(this);
     },
     methods: {
       changeS(type){
         this.$i18n.locale = type
       },
       jump(id){
         if(id){
           this.$router.push(`/Editor/?id=${id}`)
         }else{
           this.$router.push(`/Editor`)
         }
       }
     },
}
</script>

<style>

</style>